cmake_minimum_required(VERSION 3.20)

project(v1)

# 使用变量
set (SRC add.cpp sub.cpp mul.cpp div.cpp main.cpp)

# 输出日志(输出 /home/project/cmake/V1/build)
message(${PROJECT_BINARY_DIR})

# 设置文件输出路径(PROJECT_BINARY_DIR=cmake当前路径)
# 将文件生成到build/bin目录下
set (EXECUTABLE_OUTPUT_PATH ${PROJECT_BINARY_DIR}/bin)

add_executable(v1 ${SRC})